package com.yoda.mall.model.dto;

import com.yoda.mall.model.entity.sms.HomeBrand;
import lombok.Data;
import org.springframework.beans.BeanUtils;

/**
 * @author shawn
 * @date 2022年 12月 16日 19:21
 */
@Data
public class HomeBrandDto {
    private Long brandId;
    private String brandName;

    public static HomeBrand init(HomeBrandDto dto){
        HomeBrand homeBrand = new HomeBrand();
        BeanUtils.copyProperties(dto,homeBrand);
        homeBrand.setSort(0);
        homeBrand.setRecommendStatus(0);
       return homeBrand;
    }
}
